//
//  ViewController.m
//  SFAlertBlock
//
//  Created by sun on 15/9/20.
//  Copyright © 2015年 sunfei. All rights reserved.
//

#import "ViewController.h"

#import "UIAlertView+BlockAddition.h"

@interface ViewController ()

@end

@implementation ViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    
    UIAlertView *alertView = [UIAlertView alertViewWithTitle:@"sunfei"
                                                     message:@"xiaoruinihao"
                                           cancelButtonTitle:@"no"
                                           otherButtonTitles:@[@"yes"]
                                                   onDismiss:^(NSInteger buttonIndex) {
                                                       if (buttonIndex == 0) {
                                                           NSLog(@"nihao");
                                                       }
                                                   } onCancel:^{
                                                       NSLog(@"buhao");
                                                   }];
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];

}

@end
